<include file="public@header"/>
<style>
.cdnhide{
	display:none;
}
.codehide{
	display:none;
}

.msg_tips{
    color: #FF6A00;
}
</style>
</head>
<body>
<div class="wrap js-check-wrap">
    <ul class="nav nav-tabs">
        <li  class="active"><a href="#B" data-toggle="tab">登录配置</a></li>
        <li><a href="#C" data-toggle="tab">直播配置</a></li>
 
        <li><a href="#O" data-toggle="tab">云存储配置</a></li>
    </ul>
    <form class="form-horizontal js-ajax-form margin-top-20" role="form" action="{:url('setting/configpriPost')}" method="post">
        <fieldset>
            <div class="tabbable">
                <div class="tab-content">

                    <div class="tab-pane active" id="B">
                        <div class="form-group">
                            <label for="input-reg_reward" class="col-sm-2 control-label">注册奖励</label>
                            <div class="col-md-6 col-sm-10">
                                <input type="text" class="form-control" id="input-reg_reward"
                                       name="options[reg_reward]" value="{$config.reg_reward|default=''}">
                                       <p class="help-block">新用户注册奖励（整数）</p>
                            </div>
                        </div>
              
                        <div class="form-group">
                            <label for="input-sendcode_switch" class="col-sm-2 control-label">短信验证码开关</label>
                            <div class="col-md-6 col-sm-10">
                                <select class="form-control" name="options[sendcode_switch]">
                                    <option value="0" selected>关闭</option>
                                </select>
                                <p class="help-block">短信验证码开关,关闭后不再发送真实验证码，采用默认验证码123456</p>
                            </div>
                        </div>

                        <div class="form-group">
                            <label for="input-iplimit_switch" class="col-sm-2 control-label">短信验证码IP限制开关</label>
                            <div class="col-md-6 col-sm-10">
								<select class="form-control" name="options[iplimit_switch]">
                                    <option value="0">关闭</option>
                                    <option value="1" <eq name="config['iplimit_switch']" value="1">selected</eq>>开启</option>
                                </select>
                            </div>
                        </div>
                        
                        <div class="form-group">
                            <label for="input-iplimit_times" class="col-sm-2 control-label">短信验证码IP限制次数</label>
                            <div class="col-md-6 col-sm-10">
                                <input type="text" class="form-control" id="input-iplimit_times" name="options[iplimit_times]" value="{$config['iplimit_times']|default=''}"> 
                                <p class="help-block">同一IP每天可以发送验证码的最大次数</p>
                            </div>
                        </div>

                        <div class="form-group">
                            <div class="col-sm-offset-2 col-sm-10">
                                <button type="submit" class="btn btn-primary js-ajax-submit" data-refresh="0">
                                    {:lang('SAVE')}
                                </button>
                            </div>
                        </div>
                    </div>
					
					
                    <div class="tab-pane" id="C">
                        <div class="form-group">
                            <label for="input-chatserver" class="col-sm-2 control-label">聊天服务器带端口</label>
                            <div class="col-md-6 col-sm-10">
                                <input type="text" class="form-control" id="input-chatserver" name="options[chatserver]" value="{$config['chatserver']|default=''}"> 
                               <p class="help-block"> 格式：http://域名(:端口) 或者 http://IP(:端口)</p>
                            </div>
                        </div>
                        
                        <div class="form-group">
                            <label for="input-live_sdk" class="col-sm-2 control-label">模式选择</label>
                            <div class="col-md-6 col-sm-10" id="sdk">
                                <label class="radio-inline"><input type="radio" value="0" name="options[live_sdk]" <in value="0" name="config['live_sdk']">checked="checked"</in>>直播模式</label>
                                <label class="radio-inline"><input type="radio" value="1" name="options[live_sdk]" <in value="1" name="config['live_sdk']">checked="checked"</in>>直播+连麦模式</label>
                            </div>
                        </div>
                        
                        <div class="form-group">
                            <label for="input-cdn_switch" class="col-sm-2 control-label">CDN</label>
                            <div class="col-md-6 col-sm-10" id="cdn">
 
                                <label class="radio-inline"><input type="radio" value="2" name="options[cdn_switch]" <in value="2" name="config['cdn_switch']">checked="checked"</in>>腾讯云</label>

                            </div>
                        </div>

                   
                        
                        <div class="cdn_bd <neq name='config.cdn_switch' value='2'>cdnhide</neq>" id="cdn_switch_2">
                            <div class="form-group">
                                <label for="input-tx_appid" class="col-sm-2 control-label">腾讯云直播appid</label>
                                <div class="col-md-6 col-sm-10">
                                    <input type="text" class="form-control" id="input-tx_appid" name="options[tx_appid]" value="{$config['tx_appid']|default=''}">
                                </div>
                            </div>
                            <div class="form-group">
                                <label for="input-tx_bizid" class="col-sm-2 control-label">腾讯云直播bizid</label>
                                <div class="col-md-6 col-sm-10">
                                    <input type="text" class="form-control" id="input-tx_bizid" name="options[tx_bizid]" value="{$config['tx_bizid']|default=''}">
                                </div>
                            </div>
                            <div class="form-group">
                                <label for="input-tx_push_key" class="col-sm-2 control-label">腾讯云推流防盗链Key</label>
                                <div class="col-md-6 col-sm-10">
                                    <input type="text" class="form-control" id="input-tx_push_key" name="options[tx_push_key]" value="{$config['tx_push_key']|default=''}"> 
                                </div>
                            </div>
                            <div class="form-group">
                                <label for="input-tx_acc_key" class="col-sm-2 control-label">腾讯云直播低延迟Key</label>
                                <div class="col-md-6 col-sm-10">
                                    <input type="text" class="form-control" id="input-tx_acc_key" name="options[tx_acc_key]" value="{$config['tx_acc_key']|default=''}">
                                    <p class="help-block">一般是 直播推流防盗链Key</p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label for="input-tx_api_key" class="col-sm-2 control-label">腾讯云直播推流鉴权key</label>
                                <div class="col-md-6 col-sm-10">
                                    <input type="text" class="form-control" id="input-tx_api_key" name="options[tx_api_key]" value="{$config['tx_api_key']|default=''}">
                                </div>
                            </div>
                            <div class="form-group">
                                <label for="input-tx_play_key" class="col-sm-2 control-label">腾讯云直播播流鉴权key</label>
                                <div class="col-md-6 col-sm-10">
                                    <input type="text" class="form-control" id="input-tx_play_key" name="options[tx_play_key]" value="{$config['tx_play_key']|default=''}">
                                </div>
                            </div>
                            <div class="form-group">
                                <label for="input-tx_play_time" class="col-sm-2 control-label">腾讯云直播播流鉴权时间(秒)</label>
                                <div class="col-md-6 col-sm-10">
                                    <input type="text" class="form-control" id="input-tx_play_time" name="options[tx_play_time]" value="{$config['tx_play_time']|default=''}">
                                </div>
                            </div>
                            <div class="form-group">
                                <label for="input-tx_play_key_switch" class="col-sm-2 control-label">是否开启腾讯云播流鉴权</label>
                                <div class="col-md-6 col-sm-10" id="sdk">
                                    <label class="radio-inline"><input type="radio" value="0" name="options[tx_play_key_switch]" <if condition="array_key_exists('tx_play_key_switch',$config) && $config['tx_play_key_switch'] eq '0'">checked="checked" </if>>关闭</label>
                                    <label class="radio-inline"><input type="radio" value="1" name="options[tx_play_key_switch]" <if condition="array_key_exists('tx_play_key_switch',$config) && $config['tx_play_key_switch'] eq '1'">checked="checked" </if>>开启</label>
                                    <p class="help-block">如果选择开启，请确保腾讯云-->云直播-->域名管理-->{$config['tx_pull']|default=''}-->管理-->访问控制-->鉴权配置 里的信息开启了配置,并保持腾讯云填写的鉴权key和鉴权时间与此处填写的一致,参考文档：<a href="https://cloud.tencent.com/document/product/267/32463" target="_blank">https://cloud.tencent.com/document/product/267/32463</a></p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label for="input-tx_push" class="col-sm-2 control-label">腾讯云直播推流域名</label>
                                <div class="col-md-6 col-sm-10">
                                    <input type="text" class="form-control" id="input-tx_push" name="options[tx_push]" value="{$config['tx_push']|default=''}">
                                    <p class="help-block"> 不带 http:// ,最后无 /</p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label for="input-tx_pull" class="col-sm-2 control-label">腾讯云直播播流域名</label>
                                <div class="col-md-6 col-sm-10">
                                    <input type="text" class="form-control" id="input-tx_pull" name="options[tx_pull]" value="{$config['tx_pull']|default=''}">
                                    <p class="help-block"> 不带 http:// ,最后无 /</p>
                                </div>
                            </div>

                            <div class="form-group">
                                <label for="input-txcloud_secret_id" class="col-sm-2 control-label">腾讯云Api密钥SecretId</label>
                                <div class="col-md-6 col-sm-10">
                                    <input type="text" class="form-control" id="input-txcloud_secret_id" name="options[txcloud_secret_id]" value="{$config['txcloud_secret_id']|default=''}">
                                    <p class="help-block">腾讯云连麦混流时身份验证，只在直播+连麦模式时才需要配置，获取方式：腾讯云后台-->用户登录账号下拉菜单-->访问管理-->访问密钥-->API密钥管理</p>
                                </div>
                            </div>
                            <div class="form-group">
                                <label for="input-txcloud_secret_key" class="col-sm-2 control-label">腾讯云Api密钥SecretKey</label>
                                <div class="col-md-6 col-sm-10">
                                    <input type="text" class="form-control" id="input-txcloud_secret_key" name="options[txcloud_secret_key]" value="{$config['txcloud_secret_key']|default=''}">
                                    <p class="help-block">腾讯云连麦混流时身份验证，只在直播+连麦模式时才需要配置，获取方式：腾讯云后台-->用户登录账号下拉菜单-->访问管理-->访问密钥-->API密钥管理</p>
                                </div>
                            </div>
                            
                        </div>


                        <div class="form-group">
                            <div class="col-sm-offset-2 col-sm-10">
                                <button type="submit" class="btn btn-primary js-ajax-submit" data-refresh="0">
                                    {:lang('SAVE')}
                                </button>
                            </div>
                        </div>
                    </div>

     
                    
     
      
                 
					
					
 
                    <!-- 云存储设置 -->
                    <div class="tab-pane" id="O">
                    
                        <div class="form-group">
                            <label for="input-cloudtype" class="col-sm-2 control-label">选择存储方式</label>
                            <div class="col-md-6 col-sm-10" id="cloudtype">
                                <label class="radio-inline"><input type="radio" value="1" name="options[cloudtype]" <in value="1" name="config['cloudtype']">checked="checked"</in>>七牛云存储</label>
            
                               
                            </div>
                        </div>
                      
    
                        <div class="form-group">
                            <div class="col-sm-offset-2 col-sm-10">
                                <button type="submit" class="btn btn-primary js-ajax-submit" data-refresh="0">
                                    {:lang('SAVE')}
                                </button>
                            </div>
                        </div>
                    </div>

                </div>
            </div>
        </fieldset>
    </form>

</div>
<script type="text/javascript" src="__STATIC__/js/admin.js"></script>

</body>
</html>
